<%-- 
    Document   : subordinadosActual
    Created on : 03/06/2011, 12:18:59 PM
    Author     : electro
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean"%>
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>  
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link href="<%=request.getContextPath()%>/css/miestilo.css" rel="stylesheet" type="text/css">
        <link href="<%=request.getContextPath()%>/css/componentes.css" rel="stylesheet" type="text/css">
        <script language="javascript" type="text/javascript" src="<%=request.getContextPath()%>/js/jquery/jquery.js"></script>
        <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery/jquery.tablesorter.js"></script>
        <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery/jquery.tablesorter.pager.js"></script>
        <script type="text/javascript">
            $(function() {
                $("#tableOne")
                .tablesorter({
                    widthFixed: true,
                    widgets: ['zebra'],
                    headers: {

                        2: {sorter: false}

                    }
                })
                .tablesorterPager({container: $("#pager"),positionFixed: false});
            });
        </script>
    </head>
    <body>
        <table>
            <tr>
                <td align="center">
                    <table>
                        <tr >
                            <td class="tituloJsp" height="35">
                                Consultas
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>

            <tr>
                <td >
                    <table cellspacing="0" cellpadding="0" align="center" border="0" class="tableToolBar" width="700px">
                        <tr bgcolor="#D6E3F2">
                            <td align="right">
                                <c:if test="${!empty requestScope.lstSubor}">
                                    <div id="pager" class="pager">
                                        <img alt="" src="<%=request.getContextPath()%>/images/jquery_table/first_old_2.png" class="first"/>
                                        <img alt="" src="<%=request.getContextPath()%>/images/jquery_table/prev_old_2.png" class="prev"/>
                                        <input type="text" class="pagedisplay selectSmall" style="text-align: center;width: 30px"/>
                                        <img alt="" src="<%=request.getContextPath()%>/images/jquery_table/next_old_2.png" class="next"/>
                                        <img alt="" src="<%=request.getContextPath()%>/images/jquery_table/last_old_2.png" class="last"/>
                                        <select class="pagesize selectSmall">
                                            <option selected="selected" value="10">10</option>
                                            <option value="20">20</option>
                                            <option  value="30">30</option>
                                        </select>
                                    </div>
                                </c:if>
                            </td>
                        </tr>
                    </table>

                    <c:if test="${!empty requestScope.lstSubor}">
                        <table id="tableOne" cellspacing="1" align="center" border="0" class="tablesorter" style="width: 700px" >
                            <thead>
                                <tr>
                                    <th width="12%"><div align="center">Nombre</div></th>
                                    <th width="10%"><div align="center">Puesto</div></th>
                                </tr>
                            </thead>
                            <tbody>
                                <c:forEach var="jbean" items="${requestScope.lstSubor}">
                                    <tr>
                                        <td align="left" >
                                            <a href="#"  onclick="clickLink('<c:out value="${jbean.strIdEmpleado}" />')"  >
                                                <c:out value="${jbean.strNombreComp}" /></a>
                                        </td>
                                        <td align="left" >
                                            <c:out value="${jbean.strDescrip_Idp}" />
                                        </td>
                                    </tr>
                                </c:forEach>
                            </tbody>
                        </table>
                    </c:if>
                    <c:if test="${empty requestScope.lstSubor}">
                        <div align="center" class="label">NO SE ENCONTRARON REGISTROS</div><br>
                    </c:if>
                </td>
            </tr>
            </table>
    </body>
     <script type="text/javascript">
     var opciones_modal="dialogHeight:800 px;dialogWidth:1010px;center:Yes;help:No;resizable: Yes;status:No;";
     
        function clickLink(obj){
            var url = '<%=request.getContextPath()%>/ConsultaAction.do?method=IrEvaluacionActual&id='+obj+'&var=2';
            var opciones="toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, width=900, height=800, top=15, left=15";
//             window.open(url,"",opciones);
            showModalDialog(url,"",opciones_modal);
        }

        function cerrar(){
            location.href = '<%=request.getContextPath()%>/a_home.do'
        }
    </script>
</html>
